#pragma once


// CProgressView view
class CCell;

class CProgressView : public CView
{
	DECLARE_DYNCREATE(CProgressView)

protected:
	CProgressView();           // protected constructor used by dynamic creation
	virtual ~CProgressView();

public:
	virtual void OnDraw(CDC* pDC);      // overridden to draw this view
#ifdef _DEBUG
	virtual void AssertValid() const;
#ifndef _WIN32_WCE
	virtual void Dump(CDumpContext& dc) const;
#endif
#endif

protected:
	DECLARE_MESSAGE_MAP()
public:
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	virtual void OnInitialUpdate();

	CCell* getCell(int i, int j);
	CCell* getNextCell(int i, int j);

	void updateItem(int i);
	CString getEstimatedProgress(CString workDays, CString passDays);
	CString getStillNeedDays(CString workDays, CString progress);
	CString isOverDue(CString estimatedProgress, CString progress);
private:
	CArray<CCell*> m_cellArray;
};


